package com.journey.org.ui.search.gank

import android.os.Bundle
import android.view.LayoutInflater
import android.view.ViewGroup
import com.journey.org.BR
import com.journey.org.R
import com.journey.org.databinding.FragmentGankSearchBinding
import com.mvvmhabit.org.base.BaseFragment
import com.mvvmhabit.org.base.BaseLazyFragment

/**
 * @Date: 2020/11/19 10:43
 * @Author:小妖
 * @Description: 干货搜索出来的展示的内容页
 */
class GankSearchFragment : BaseLazyFragment<FragmentGankSearchBinding, GankSearchViewModel>() {

    var type: String = ""

    override fun initVariableId(): Int = BR.viewModel

    override fun initViewModel(): Class<GankSearchViewModel> = GankSearchViewModel::class.java

    override fun initContentView(
        inflater: LayoutInflater?,
        container: ViewGroup?,
        savedInstanceState: Bundle?
    ): Int = R.layout.fragment_gank_search

    override fun initParam() {
        super.initParam()
        type = arguments?.getString("type")!!
    }

    override fun initData() {
        super.initData()
        mViewModel?.onSearchTypeField?.set(type)
    }

    override fun lazyLoadData() {

    }
}